<%@ page language="java" contentType="text/html; charset=UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
	<head>
		<title><s:property value='%{getText("labelIODetail_title")}' /></title>
		<link href="/SCMDB/style/main.css" rel="stylesheet" type="text/css" />
		<script type="text/javascript" src="/SCMDB/js/Super.js"></script>
		<script type="text/javascript" src="/SCMDB/js/My97DatePicker/WdatePicker.js"></script>
		<%@ include file="../commonPage/message.jsp"%>
	</head>
	<body>
		<h2>
			<s:property value='%{getText("current_position")}' />${parentMenu}>>${currentMenu}
		</h2>
		<div class="main">
			<s:form action="labelIOAction!findAll.action" method="post"
				theme="simple">
				<fieldset class="fieldSearch">
					<legend>
						<s:property value='%{getText("labelIOSearch_legend")}' />
					</legend>
					<table width="100%">
  <tr>
    <td width="7%" align="right" class="p_8">班组：</td>
    <td width="16%"><s:select name="depID" list="#request.depList" listKey="id" listValue="deptName" headerKey="0" headerValue="请选择"></s:select></td>
    <!--<td width="9%" align="right" class="p_14"><s:property value='%{getText("emp_new_zw")}' /></td>
    <td width="18%"><s:select name ="dutyID" list="#request.dutyList" listKey="id" listValue="name" headerKey="0" headerValue="请选择"></s:select></td>
    --><td width="9%" align="right" class="p_14">岗位/工种：</td>
    <td width="17%"><s:select name ="workTypeID" list="#request.workTypeList" listKey="id" listValue="name" headerKey="0" headerValue="请选择"></s:select></td>
    <td width="9%" align="right" class="p_14"><s:property value='%{getText("emp_new_xm")}' /></td>
    <td width="15%"><s:textfield cssClass="sInput" name="entity.empName"></s:textfield></td>
  </tr>
  <tr>
    <td align="right" class="p_8"><s:property value='%{getText("emp_new_kh")}' /></td>
    <td><s:textfield cssClass="sInput" name="entity.labelID"></s:textfield><input type="hidden" value="must-number" /></td>
    <td align="right" class="p_14"><s:property value='%{getText("labelIOSearch_statrtTime")}' /></td>
    <td><s:textfield id="inTime" name="entity.inTime" cssClass="timeInput" title="开始时间" readonly="true" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})"></s:textfield></td>
    <td align="right" class="p_14"><s:property value='%{getText("labelIOSearch_endTime")}' /></td>
    <td><s:textfield id="outTime" name="entity.outTime" cssClass="timeInput" title="结束时间" readonly="true" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})"></s:textfield></td>
    <td></td>
    <td class="p_14"><input type="button" id="bSearch" name="search" class="bSearch"
						value="查询" onClick="loading()" /></td>
  </tr>
</table>

				</fieldset>
				<table border="0" cellpadding="1" cellspacing="1" class="tableList">
					<thead>
						<tr>
							<th width="30" class="number">
								<s:property value='%{getText("emp_th1")}' />
							</th>
							<th width="15%">
								<s:property value='%{getText("emp_th3")}' />
							</th>
							<th width="15%">
								编号
							</th>
							<th width="25%">
								班组
							</th><!--
							<th width="15%">
								<s:property value='%{getText("emp_th6")}' />
							</th>
							--><th width="25%">
								岗位/工种
							</th>
							<th width="15%">
								<s:property value='%{getText("labelIOSearch_gjxx")}' />
							</th>
						</tr>
					</thead>

					<tbody>
						<s:iterator id="pageBean" status="u"
							value="#session.labelIOBean.list">
							<tr>
								<td class="number">
									${entity.index+u.index}
								</td>
								<td>
								<a href="#" onclick="Super.Popup(5,'查询','/SCMDB/employeeAction!findEmp.action?id=${pageBean.empID}','',700,600);">
										${pageBean.empName} 
									</a>
								</td>
								<td>
									${pageBean.labelID}
								</td>
								<td>
									${pageBean.depID}
								</td><!--
								<td>
									${pageBean.dutyID}
								</td>
								--><td>
									${pageBean.workTypeID}
								</td>
								<td>
								<a onclick="showDetail('${pageBean.empID}')"  style="color:blue;cursor:pointer;"><s:property value='%{getText("labelIOSearch_Search")}' /></a>
								</td>
							</tr>
						</s:iterator>
						<tr>
							<td colspan="9" class="turnPage"><jsp:include flush="true" page="../commonPage/page.jsp"><jsp:param name="entity" value="entity" />
								</jsp:include>
							</td>
						</tr>
					</tbody>
				</table>
			</s:form>
		</div>
		<div id="loading" style="display: none;"></div>
	</body>
</html>
<script>
function showDetail(empID){
	document.forms[0].action="/SCMDB/labelIOAction!findHisDetail.action?id="+empID;
	document.forms[0].submit();
}
</script>

